package util

import (
	"os"
	"strings"
)

var (
	Key = "caipu"
)

func GetProgramPath() string {
	path, _ := os.Getwd()
	if !strings.Contains(path, Key) {
		panic("admin only run caipu dir ")
	}
	//index := strings.Index(path, Key)
	//if index == 0 {
	//	return ""
	//}
	//return path[0 : index+5]
	return path
}
